using System.Collections.Generic;
using System.Linq.Expressions;
using Microsoft.EntityFrameworkCore.Query;

namespace Microsoft.EntityFrameworkCore.Dm.Query.Internal;

internal class DmRelationalParameterBasedSqlProcessor : RelationalParameterBasedSqlProcessor
{
	public DmRelationalParameterBasedSqlProcessor(RelationalParameterBasedSqlProcessorDependencies dependencies, bool useRelationalNulls)
		: base(dependencies, useRelationalNulls)
	{
	}

	protected override Expression ProcessSqlNullability(Expression selectExpression, IReadOnlyDictionary<string, object?> parametersValues, out bool canCache)
	{
		return new DmSqlNullabilityProcessor(this.Dependencies, this.UseRelationalNulls).Process(selectExpression, parametersValues, out canCache);
	}
}
